{
GtkShadow *box_shadow;
- gtk_style_context_get (bg->context, bg->flags,
- "box-shadow", &box_shadow,
- NULL);
+ box_shadow = _gtk_css_value_get_shadow (_gtk_style_context_peek_property (bg->context, "box-shadow"));
if (box_shadow != NULL)
{
_gtk_box_shadow_render (box_shadow, cr, &bg->padding_box);
- _gtk_shadow_unref (box_shadow);
}
}
fg_color.alpha = CLAMP (fg_color.alpha + ((other_fg.alpha - fg_color.alpha) * progress), 0, 1);
}
- gtk_theming_engine_get (engine, flags,
- "text-shadow", &text_shadow,
- NULL);
+ text_shadow = _gtk_css_value_get_shadow (_gtk_theming_engine_peek_property (engine, "text-shadow"));
prepare_context_for_layout (cr, x, y, layout);
if (text_shadow != NULL)
{
_gtk_text_shadow_paint_layout (text_shadow, cr, layout);
- _gtk_shadow_unref (text_shadow);
}
gdk_cairo_set_source_rgba (cr, &fg_color);
radius = MIN (width / 2, height / 2);
gtk_theming_engine_get_color (engine, state, &color);
- gtk_theming_engine_get (engine, state,
- "icon-shadow", &shadow,
- NULL);
+ shadow = _gtk_css_value_get_shadow (_gtk_theming_engine_peek_property (engine, "icon-shadow"));
cairo_save (cr);
cairo_translate (cr, x + width / 2, y + height / 2);
_gtk_icon_shadow_paint_spinner (shadow, cr,
radius,
progress);
- _gtk_shadow_unref (shadow);
}
_gtk_theming_engine_paint_spinner (cr,
gdouble x,
gdouble y)
{
- GtkStateFlags state;
GtkShadow *icon_shadow;
- state = gtk_theming_engine_get_state (engine);
-
cairo_save (cr);
gdk_cairo_set_source_pixbuf (cr, pixbuf, x, y);
- gtk_theming_engine_get (engine, state,
- "icon-shadow", &icon_shadow,
- NULL);
+ icon_shadow = _gtk_css_value_get_shadow (_gtk_theming_engine_peek_property (engine, "icon-shadow"));
if (icon_shadow != NULL)
{
_gtk_icon_shadow_paint (icon_shadow, cr);
- _gtk_shadow_unref (icon_shadow);
}
cairo_paint (cr);